package com.snoopy.gas1.mapper;

import com.snoopy.gas1.entity.Oil_info;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
@Mapper
public interface Oil_infoMapper {
    // 查询所有油品
    List<Oil_info> lists();

    // 根据名称模糊查询
    List<Oil_info> searchByName(String name);

    // 根据ID删除
    void deleteById(int id);

    // 添加油品
    int add(Oil_info oilInfo);

    // 根据ID查询
    Oil_info getById(int id);

    // 更新油品信息
    int update(Oil_info oilInfo);
}
